package com.fagejiang.springbootmybatis.controller;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.fagejiang.springbootmybatis.domain.UserConfig;
import com.fagejiang.springbootmybatis.mapper.UserConfigMapper;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * TODO
 *
 * @author 发哥讲Java
 * @version 1.0
 * @date 2021-03-24 15:19
 */
@RestController
public class TestController {
    @Resource
    UserConfigMapper userConfigMapper;

    @GetMapping("/test")
    public Object getObject() {
        return userConfigMapper.selectOne(new QueryWrapper<UserConfig>().eq("user_code", "test2"));
    }

}
